{% extends "base.html" %}

{% block title %}Statistics{% endblock %}

{% block content %}
<h2>Statistics</h2>
<p>
{% if total_count %}
Blog entity: {{ total_count|intcomma }}<br/>
&nbsp;&nbsp;Accepted: {{ accepted_count|intcomma }} ({{ accepted_percentage|floatformat:2 }}%)<br/>
&nbsp;&nbsp;Blocked: {{ blocked_count|intcomma }} ({{ blocked_percentage|floatformat:2 }}%)<br/>
&nbsp;&nbsp;In Review: {{ review_count|intcomma }} ({{ review_percentage|floatformat:2 }}%)<br/>
{% else %}
Blog entity: Unavailable<br/>
&nbsp;&nbsp;Accepted: Unavailable<br/>
&nbsp;&nbsp;Blocked: Unavailable<br/>
&nbsp;&nbsp;In Review: Unavailable<br/>
{% endif %}
Post entity count: {{ db_post_count|intcomma }}<br/>
Active blog count: {{ active_blogs_count|intcomma }} (Resets hourly)<br/>
Completed Requests: {{ completed_requests|intcomma }} (Last 24 Hours)
</p>
<h2>Charts</h2>
<p style="text-align:center">Charts are regenerated every 5 minutes.</p>
<h3>Completed requests</h3>
<p style="text-align:center">
<img src="{# This is a XML+HTML, therefore escape the html #}{{ chart_uri|escape }}" alt="Chart of completed requests in last 24 hours" title="Chart of completed requests in last 24 hours"/>
</p>
<h3>Active blogs</h3>
<p style="text-align:center">
<img src="{# This is a XML+HTML, therefore escape the html #}{{ chart_uri_active_blogs|escape }}" alt="Chart of active blogs in last 24 hours" title="Chart of active blogs in last 24 hours"/><br/>
</p>
{% endblock %}
